#!/bin/sh

# Path for the record file
RECORD_FILE="/etc/sysp/usb"

# Check if 'lsusb -t' contains 'rtl88x2bu'
if lsusb -t | grep -q "rtl88x2bu"; then
    echo "true"
    # Create or overwrite the record file with '1'
    echo '1' > "$RECORD_FILE"
    mv /etc/sysp/usbcheck/pifi_checkusb_setup /etc/sysp/
    chmod +x /etc/sysp/pifi_checkusb_setup
else
    echo 'nope'
fi